#ifndef __LOGGER_HPP__
#define __LOGGER_HPP__
 
 
#include <string>
#include <stdarg.h>
 
#define LOGF(...) __log_info(Level::FATAL, __VA_ARGS__)
#define LOGE(...) __log_info(Level::ERROR, __VA_ARGS__)
#define LOGW(...) __log_info(Level::WARN,  __VA_ARGS__)
#define LOGI(...)  __log_info(Level::INFO,  __VA_ARGS__)
#define LOGV(...) __log_info(Level::VERB,  __VA_ARGS__)
#define LOGD(...) __log_info(Level::DEBUG, __VA_ARGS__)
 
#define DGREEN    "\033[1;36m"
#define BLUE      "\033[1;34m"
#define PURPLE    "\033[1;35m"
#define GREEN     "\033[1;32m"
#define YELLOW    "\033[1;33m"
#define RED       "\033[1;31m"
#define CLEAR     "\033[0m"
 
 
enum class Level : int32_t{
    FATAL = 0,
    ERROR = 1,
    WARN  = 2,
    INFO  = 3,
    VERB  = 4,
    DEBUG = 5
};
 
extern Level GLOB_LEAVEL;
 
// 全局日志级别设置
 
void SET_LOG_LEVEL(Level level);
 
void __log_info(Level level, const char* format, ...);
 
 
// 头文件内容放在这里
 
#endif // __LOGGER_HPP__